package com.exam.service;

import java.util.Date;

import javax.servlet.http.HttpSession;

import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;

import com.common.util.TablePage;
import com.exam.entity.Exam;
import com.mark.entity.StuAnswer;
import com.paper.entity.Paper;

public interface IExamService {
	public TablePage<Exam> findPage(Specification<Exam> spec,Pageable pageable);
	public void save(Exam exam);
	public void cancel(Long id);
	public void publish(Exam exam);
	public Exam findOne(Long id);
	public Exam attendExam(Long stuId,Long eId);
	public String startExam(HttpSession session,Long examId);
	public boolean isNumExist(Exam exam);
	public boolean isRunningOrEnd(Long id);
	public void delete(Long id);
	public Paper loadPaper(Long examId);
	public StuAnswer loadStuAnswer(Long stuId,Long examId);
	public Date getCurrentDate();
}
